package com.hailiao.beidou.message.bd.constant

import androidx.compose.ui.graphics.Color

/**
 * 协议版本
 * @Author d10ng
 * @Date 2024/3/4 16:24
 */
enum class ProtoVersion(val id: Double, val text: String, val shortText: String, val color: Color) {
    BD2(2.1, "北斗2.1标准协议", "北二", Color(0xFFFF3366)),
    BD3(3.0, "北斗3.0标准协议", "北三", Color(0xFFCC33FF)),

    ;
    companion object {
        fun parse(id: Double) = entries.firstOrNull { it.id == id } ?: BD3
    }
}